home *** CD-ROM | disk | FTP | other *** search
/ Sprite 1984 - 1993 / Sprite 1984 - 1993.iso / man / lib.fmt / c / unlink.man < prev    next >
Encoding:
Text File  |  1989-02-02  |  2.8 KB  |  133 lines

  1.  
  2.  
  3.  
  4. UNLINK                C Library Procedures                 UNLINK
  5.  
  6.  
  7.  
  8. NNAAMMEE
  9.      unlink - remove directory entry
  10.  
  11. SSYYNNOOPPSSIISS
  12.      uunnlliinnkk((ppaatthh))
  13.      cchhaarr **ppaatthh;;
  14.  
  15. DDEESSCCRRIIPPTTIIOONN
  16.      _U_n_l_i_n_k removes the entry for the file _p_a_t_h from its direc-
  17.      tory.  If this entry was the last link to the file, and no
  18.      process has the file open, then all resources associated
  19.      with the file are reclaimed.  If, however, the file was open
  20.      in any process, the actual resource reclamation is delayed
  21.      until it is closed, even though the directory entry has
  22.      disappeared.
  23.  
  24. RREETTUURRNN VVAALLUUEE
  25.      Upon successful completion, a value of 0 is returned.  Oth-
  26.      erwise, a value of -1 is returned and _e_r_r_n_o is set to indi-
  27.      cate the error.
  28.  
  29. EERRRROORRSS
  30.      The _u_n_l_i_n_k succeeds unless:
  31.  
  32.      [ENOTDIR]      A component of the path prefix is not a
  33.                     directory.
  34.  
  35.      [EINVAL]       The pathname contains a character with the
  36.                     high-order bit set.
  37.  
  38.      [ENAMETOOLONG] A component of a pathname exceeded 255 char-
  39.                     acters, or an entire path name exceeded 1023
  40.                     characters.
  41.  
  42.      [ENOENT]       The named file does not exist.
  43.  
  44.      [EACCES]       Search permission is denied for a component
  45.                     of the path prefix.
  46.  
  47.      [EACCES]       Write permission is denied on the directory
  48.                     containing the link to be removed.
  49.  
  50.      [ELOOP]        Too many symbolic links were encountered in
  51.                     translating the pathname.
  52.  
  53.      [EPERM]        The named file is a directory and the effec-
  54.                     tive user ID of the process is not the
  55.                     super-user.
  56.  
  57.      [EPERM]        The directory containing the file is marked
  58.                     sticky, and neither the containing directory
  59.                     nor the file to be removed are owned by the
  60.  
  61.  
  62.  
  63. Sprite v1.0               May 22, 1985                          1
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. UNLINK                C Library Procedures                 UNLINK
  71.  
  72.  
  73.  
  74.                     effective user ID.
  75.  
  76.      [EBUSY]        The entry to be unlinked is the mount point
  77.                     for a mounted file system.
  78.  
  79.      [EIO]          An I/O error occurred while deleting the
  80.                     directory entry or deallocating the inode.
  81.  
  82.      [EROFS]        The named file resides on a read-only file
  83.                     system.
  84.  
  85.      [EFAULT]       _P_a_t_h points outside the process's allocated
  86.                     address space.
  87.  
  88. SSEEEE AALLSSOO
  89.      close(2), link(2), rmdir(2)
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129. Sprite v1.0               May 22, 1985                          2
  130.  
  131.  
  132.  
  133.